package entity;
/*
 *ClassName:PageResult
 *Description:返回分页结果的实体类
 *@author:可爱的大鸭子
 */

import java.util.List;

public class PageResult<T> {
    private int current;    //当前的页码
    private Long total;     //查询到的记录数
    private List<T> rows;   //查询到的数据列表

    public PageResult(Long total, List<T> rows) {
        this.total = total;
        this.rows = rows;
    }
    public PageResult(int current,Long total,List<T> rows){
        this.current=current;
        this.total = total;
        this.rows = rows;
    }

    public int getCurrent() {
        return current;
    }

    public void setCurrent(int current) {
        this.current = current;
    }

    public Long getTotal() {
        return total;
    }

    public void setTotal(Long total) {
        this.total = total;
    }

    public List<T> getRows() {
        return rows;
    }

    public void setRows(List<T> rows) {
        this.rows = rows;
    }
}
